[ACM] An environment where ACM and its tools have not been installed before
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Thu, 19 Oct 2006 14:15:36 +0000 (15:15 +0100)
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Thu, 19 Oct 2006 14:15:36 +0000 (15:15 +0100)
will throw an error during 'make' of the test suite. This fixes the problem.

Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
tools/xm-test/tests/security-acm/01_security-acm_basic.py
tools/xm-test/tests/security-acm/Makefile.am

index 569b004c1880fafa846bc005480d316ce9056b81..6459bb9fd875b3b95cc36d68088920a5a920e6da 100644 (file)
@@ -24,6 +24,9 @@ testlabel = "blue"
 vmconfigfile = "/tmp/xm-test.conf"
 testresource = "phy:ram0"
 
+if not isACMEnabled():
+    SKIP("Not running this test since ACM not enabled.")
+
 status, output = traceCommand("xm makepolicy %s" % (testpolicy))
 if status != 0 or output != "":
     FAIL("'xm makepolicy' failed with status %d and output\n%s" %
index b2979b842a0df0d9a810dff86361943cb72cb7b4..7b691712f212f23bb7f3f51ec075909e1aaae964 100644 (file)
@@ -15,7 +15,10 @@ TESTS_ENVIRONMENT=@TENV@
 %.test: %.py
        cp $< $@
        chmod +x $@
-       @cp -f xm-test-security_policy.xml /etc/xen/acm-security/policies
+       @if [ -d /etc/xen/acm-security/policies ]; then \
+               cp -f xm-test-security_policy.xml      \
+                     /etc/xen/acm-security/policies;  \
+       fi;
 
 clean-local: am_config_clean-local